package com.ant.backstage.service;

import com.ant.backstage.facade.ApiReturn;
import com.ant.backstage.facade.dto.UserDTO;
import com.ant.backstage.facade.model.Role;
import com.ant.backstage.facade.request.power.AllocationRoleRequest;
import com.ant.backstage.facade.request.power.RoleAddRequest;
import com.github.pagehelper.PageInfo;

import java.util.List;

public interface RoleService {

    Role selectRolesById(int id);

    ApiReturn addRole(RoleAddRequest roleAddRequest, UserDTO userPo);

    ApiReturn updateRolesStatus(String statusId, String roleId, ApiReturn apiReturn, UserDTO userPo);

    PageInfo selectRoles(Role role, int pageNum, int pageSize, String uid);

    List<Role> selectAllRole();

    ApiReturn removeRolePermission(String roleId, String perId, UserDTO userPo);

    ApiReturn allocationRolePermission(AllocationRoleRequest allocationRoleRequest, UserDTO userPo);

    List<Role> selectRolesByUid(String uid);
}
